package com.ebraga.trackerclub.android.manager.service;

import com.ebraga.trackerclub.android.dao.api.ParameterDao;
import com.ebraga.trackerclub.android.dao.api.UserDao;
import com.ebraga.trackerclub.android.dao.api.webservice.LoginLdapWSDao;
import com.ebraga.trackerclub.android.dao.service.ParameterServiceDao;
import com.ebraga.trackerclub.android.dao.service.UserServiceDao;
import com.ebraga.trackerclub.android.manager.core.LoginManagerImpl;
import com.ebraga.trackerclub.android.util.api.AndroidContext;
import com.ebraga.trackerclub.android.util.core.DataAccessObjectImpl;

public class LoginServiceManager extends LoginManagerImpl {
	
	public LoginServiceManager(AndroidContext context) {
		
		String enviroment = System.getProperty("Enviroment");
		
		if ( enviroment == null || !enviroment.equals("UNIT_TEST") ) {
			
			setParameterDao(new ParameterServiceDao(new DataAccessObjectImpl(context)));
			setUserDao(new UserServiceDao(new DataAccessObjectImpl(context)));
			
			
		} 
	}
	
	public void setLoginLdapWSDao (LoginLdapWSDao loginLdapWSDAO){
		super.setLoginLdapWSDao(loginLdapWSDAO);
	}
	
	public void setUserDao (UserDao userDao){
		super.setUserDao(userDao);
	}
	
	public void setParameterDao (ParameterDao parameterDao){
		super.setParameterDao (parameterDao);
	}

}
